<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
        <title>WeData数据显示</title>
        <script src="../../src/Init.js"></script>
        <script src="WeDataPart/ArtTreeView.js"></script>
        <script src="WeDataPart/WeDataNodeView.js"></script>
        <script src="weData_test.js"></script>
        <style>
            body {
                background-color: #3a3c62;
                
            }
            
            #WeData_Save {
                color: #d71920;
                margin-left: 10px; /*X方向偏移*/
                margin-top: 1px; /*Y方向偏移*/
                width: 104px;
                height: 25px;
                background: transparent;
                /*border: none;*/
                font-size: 12px;
                font-weight: 700;
            }
            
            #WeData_Load {
                color: #00ff00;
                margin-left: 10px; /*X方向偏移*/
                margin-top: 20px; /*Y方向偏移*/
                width: 104px;
                height: 25px;
                background: transparent;
                /*border: none;*/
                font-size: 12px;
                font-weight: 700;
            }
            
            .WeData {
                
            }
            
            .btn01 {
                color: #00ff00;
                margin-left: 10px; /*X方向偏移*/
                margin-top: 20px; /*Y方向偏移*/
                width: 104px;
                height: 25px;
                background: transparent;
                /*border: none;*/
                font-size: 12px;
                font-weight: 700;
            }
        </style>
    </head>
    <body>
        <div id="rootDiv" class="WeData">
            <a href="../../index.html" target="_self">返回</a>
            <br/>
            <button id="WeData_Save" type="button" onclick="WeData_Save()">WeData_Save</button>
            <button id="WeData_Load" type="button" onclick="WeData_Load()">WeData_Load</button>
            <button class="btn01" type="button" onclick="WeData_get()">WeData_get</button>
            <button class="btn01" type="button" onclick="ArtTreeView.Open(rootDiv,prjDir)">打开资源列表</button>
        </div>
    
    </body>
</html>

<script>
    let rootDiv = document.getElementById('rootDiv');
    let prjDir = "/Users/mac/work/gitxia9000/unity3d/U3d_Packages/Assets";

    
    function WeData_Save(ss = "保存") {
        ss = ss == null ? "保存" : ss;
        console.log("sssssssssssssssss__________" + ss);
        
        let filePath = "/Users/mac/Desktop/test_js/sssss.txt"
        let fileData = "/Users/mac/Desktop/test_js/sssss.txt\r\nddsdhiofh单身快乐发窘大开杀戒覅偶就是滴哦\r\t asdhauhsdiha艾斯欧代发iOS大家哦"
        WebPost_FileSave(filePath, fileData, function (dataStr) {
            console.log(dataStr);
        })
    }
    
    function WeData_Load() {
        let filePath = "/Users/mac/Desktop/test_js/sssss.txt"
        WebPost_FileRead(filePath, "text", function (data) {
            console.log("WeData_Load.消息响应________" + data);
            alert(data);
        })
    }
    
    let str = "409.99";
    let ii = parseFloat(str)
    let ii2 = Number(str)
    let str33 = "44"; 
    
    WeDataNodeView(rootDiv);
    
    // insert1(root);

</script>